Databases organize collections of data into records. The records can be organized into sets and/or tables. Databases can be stored on disk, or in memory. An on disk database stores relevant data on stable storage such as hard disks, optical discs, or flash memory. Disk storage allows for cheaper storage and/or more space for storage of relevant data compared to storage in computer memory.
Compared with on disk databases, in memory databases rely primarily on main memory such as Random Access Memory (RAM). Because memory storage can perform faster than disk storage, in memory databases often perform faster than on disk databases, for example because the number of seeks to disk required is lowered.